
{php $bisaiyituoguan = \Phpcmf\Service::M()->db->table('1_'.MOD_DIR.'_bisaifufei')->where('cid', $id)->where('leixing', 1)->where('uid', $uid)->get()->getRowArray();}
{php $bisaijifenzhifu = \Phpcmf\Service::M()->db->table('1_'.MOD_DIR.'_bisaijifen')->where('cid', $id)->where('leixing', 1)->where('uid', $uid)->get()->getRowArray();}
<div class="d-shang-15">
	<div class="d-kuan d-beijingyanse-hong d-yuanjiao-10 ">
		<div class="d-neikuang-10">
			<div class="col-md-6">
				<div class="d-jiacu" style="color: #ef611a;">比赛</div>
				
					
				{if $jlfs == '1'}
					{if $uid == $member.id}
						<div class="d-shang-10 d-quxian-0">
							<span class="d-zitiyanse-hui">您的{SITE_SCORE} </span>
							<span class="d-zuo-10 d-wenzi-14 d-shang-10" style="color: #ff7171;"> <img class="" src="{HOME_THEME_PATH}web/img/jinbi.svg" height="15" width="15"/> {$member.score}</span>
						</div>
					{/if}
				{else}
					{if $uid == $member.id}
						<div class="d-shang-10 d-quxian-0">
							<span class="d-zitiyanse-hui">您的余额</span>
							
							<span class="d-zuo-10 d-wenzi-14 d-shang-10" style="color: #ff7171;"> <i class="fa fa-jpy"></i> {$member.money}</span>
							
						</div>
					{/if}
				{/if}
					<div class="d-shang-10">
						<span class="d-zitiyanse-hui">支付状态</span>
						{loop $mcjl $i $v}
						    {php $sum += intval($v[2]);}
						{/loop}
						{if $bisaiyituoguan || $bisaijifenzhifu}
						<span class="d-zuo-10 d-wenzi-14 d-shang-10" style="color: #ff7171;"> <i class="fa fa-check-circle"></i> 已托管</span>
						{else}
							{if $uid == $member.id}
								{if $jlfs == '2'}
								<a href="{dr_url(MOD_DIR.'/buybisai/index', ['fid' => 0,'id'=> $id, 'jiangli' => $sum])}">
								
									<span class="d-zuo-10 d-shang-10 d-jindu-ziti {if $zhaopinbiao}d-jiacu d-beijing-wenzi-hongse-1{/if} d-wenzi-14" style="color: #d52929;">
										<i class="fa fa-hourglass-start"></i> 待支付 {$sum} {if $jlfs == '1'}{SITE_SCORE} {else} 元{/if}
									</span>
								</a>
								{else}
								<a href="{dr_url(MOD_DIR.'/buybisai/bisaijifen', ['fid' => 0,'id'=> $id])}">
									<span class="d-zuo-10 d-wenzi-14 d-shang-10" style="color: #ff7171;">  待支付 {$sum} 积分</span>
								</a>
								{/if}
							{else}
							<span class="d-zuo-10 d-wenzi-14 d-shang-10" style="color: #ff7171;"> <i class="fa fa-hourglass-start"></i> 待支付</span>
							{/if}
						{/if}
					</div>
				
				
				<div class="d-shang-10">
					<span class="d-zitiyanse-hui">结束时间</span>
					<span class="d-zuo-10">
						{$bsjssj}
					</span>
					
				</div>
				<div class="d-shang-10">
					<span class="d-zitiyanse-hui">实名参与</span>
					<span class="d-zuo-10">
						{if $bssmcy == '1'}不需要
						{elseif $bssmcy == '2'}需要实名
						{/if}
					</span>
				</div>
				<div class="d-clear"></div>
			</div>
			{if !$shifouzhongbiao}
			<div class="col-md-6 ">
				<div class="d-kuan d-shang-20 d-kuan-160 d-beijing-fenhong d-yuanjiao-10 d-wenzi-juzhong d-zitiyanse-bai d-kuan-juzhong">
					{if strtotime($bsjssj) < time()}
						<a  class="d-hanggao-40" style="" >
							<i class="fa fa-trophy"></i> 时间结束了
						</a>
					{else}
						
						{if $member}
						    {if $zdyh}
							    {member IN_id=$zdyh return=r}
									
									{if $r.id == $member.id}
									    {if $shenhe ==1}
									    <a id="d-zhaopin-lianxi" class="d-hanggao-40" style="" onclick="javascript:d_bisan_2();">
										    <i class="fa fa-trophy"></i> 我来参加
									    </a>
									    {else}
									    <a id="d-zhaopin-lianxi" class="d-hanggao-40" style="">
										    <i class="fa fa-trophy"></i> 审核中...
									    </a>
									    {/if}
									
									{/if}
								{/member}
							{else}
							        {if $shenhe ==1}
									    <a id="d-zhaopin-lianxi" class="d-hanggao-40" style="" onclick="javascript:d_bisan_2();">
								            <i class="fa fa-trophy"></i> 我来参加
								        </a>
									    {else}
									    <a id="d-zhaopin-lianxi" class="d-hanggao-40" style="">
										    <i class="fa fa-trophy"></i> 审核中...
									    </a>
									{/if}
								
							{/if}
						{else}
						<a class="d-hanggao-40" style="" href="{dr_member_url("login/index", ["back" => urlencode($my_web_url)])}">
							<i class="fa fa-trophy"></i> 登录后参加
						</a>
						{/if}
					{/if}
				</div>
				
			</div>
			{/if}
			
			
			<div class="d-clear"></div>
			
		</div>
			<div class="d-clear"></div>
			
		<!---->
		

		
		<div class="d-kuan">
			{loop $mcjl $i $v}
			
				{if $i == '2'}
				<div class="d-kuan-33 d-wenzi-juzhong pull-left">
					<div class="" style="height: 60px;line-height: 60px;">{$v[2]} {if $jlfs == '1'}{SITE_SCORE} {else} 元{/if}</div>
					<div class="d-zitiyanse-bai d-wenzi-14" style="height: 70px;line-height: 70px;background-color: #ffb2b2;border-radius: 10px 0px 0 0;">{$v[1]}</div>
				</div>
				{/if}
				
			{/loop}
			{loop $mcjl $i $v}
				{if $i == '1'}
				<div class="d-kuan-33 d-wenzi-juzhong pull-left">
					<div class="d-jiacu" style="height: 30px;line-height: 30px;"><i class="fa fa-trophy d-wenzi-30 " style="color: #f88585;"></i><br>
					<span style="color: #ffffff;">{$v[2]} {if $jlfs == '1'}{SITE_SCORE} {else} 元{/if}</span></div>
					<div class="d-gao-100 d-beijing-fenhong d-yuanjiao-10-10 d-zitiyanse-bai d-wenzi-14" style="line-height: 100px;">{$v[1]}</div>
				</div>
				{/if}
				
			{/loop}
			{loop $mcjl $i $v}

				{if $i == '3'}
				<div class="d-kuan-33 d-wenzi-juzhong pull-left">
					<div class="" style="height: 80px;line-height: 80px;">{$v[2]} {if $jlfs == '1'}{SITE_SCORE} {else} 元{/if}</div>
					<div class=" d-zitiyanse-bai d-wenzi-14" style="line-height: 50px;height: 50px;background-color: #ffbfbf;border-radius: 0 10px 0px 0;">{$v[1]}</div>
				</div>
				{/if}
			{/loop}
			
		</div>
		<div class="d-clear"></div>
		<div class="d-kuan  d-xia-10">
		{loop $mcjl $i $v}
		{if $i > 3}
		<div class="col-xs-12 d-wenzi-juzhong d-shang-10" >
			<div style="height: 40px;line-height: 40px;background-color: #ffeaea;">
				<div class="pull-left d-zuo-10" style="height: 40px;line-height: 40px;">{$v[1]}</div>
				<div class="pull-right d-you-10 d-yuanjiao-10-10  d-wenzi-14" style="line-height: 40px;height: 40px;">
					{$v[2]} {if $jlfs == '1'}{SITE_SCORE} {else} 元{/if}
				</div>
			</div>
			
		</div>
		{/if}
		{/loop}
		</div>
		<div class="d-clear "></div>
		<div class="d-kuan d-gao-10"></div>
		
	</div>
	
	<div class="d-kuan d-shang-15">
		<div class="d-kuan d-shang-15 d-wenzi-18 d-xia-15 d-wenzi-juzhong d-jiacu">比赛规则</div>
		
	</div>
	<div class="d-clear"></div>
	
</div>
<!--提交答案-->

<style>
.d-beijingyanse-hong {
	background-color: #fff6f6;
	border-radius: 10px !important;
}
.xia-20 {
	margin-bottom: 20px;
	
}
</style>


<script>
function d_bisan_2() {
    dr_iframe("{dr_lang('提交答案')}", "{dr_member_url(MOD_DIR.'/bisai/adddaan', ['cid'=>$index.id,'tid'=>$id])}", '100%', '100%');
}

</script>